package com.zosean.sky.main;

import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;

/**
 * <p>Title: </p>
 *
 * <p>Description: </p>
 *
 * <p>Copyright: Copyright (c) 2009</p>
 *
 * <p>Company: </p>
 *
 * @author sky
 * @version 1.0
 */
public class Midlet extends MIDlet {
    public static Midlet instance;
    public MainCanvas mc;
    private Display dis;
    public Midlet()
    {
        if(instance == null)
            instance = this;
        if(mc == null)
            mc = new MainCanvas();
        if(dis == null)
            dis = Display.getDisplay(this);
    }
    /**
     * start method
     * game start or resume
     */
    public void startApp()
    {
        dis.setCurrent(mc);
    }
    /**
     * pause method
     */
    public void pauseApp()
    {
    }
    /**
     * @param b boolean
     */
    public void destroyApp(boolean b)
    {

    }
    /**
     * quite game
     */
    public static void quitApp()
    {

    }
}
